﻿<Page xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation" xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml" xmlns:mc="http://schemas.openxmlformats.org/markup-compatibility/2006" xmlns:d="http://schemas.microsoft.com/expression/blend/2008" xmlns:my="clr-namespace:BlueHarvestSnippetGenerator" xmlns:visualizationToolkit="clr-namespace:System.Windows.Controls.DataVisualization;assembly=System.Windows.Controls.DataVisualization.Toolkit" xmlns:chartingToolkit="clr-namespace:System.Windows.Controls.DataVisualization.Charting;assembly=System.Windows.Controls.DataVisualization.Toolkit" x:Class="BlueHarvestSnippetGenerator.Pages.Achievement" 
	  d:DesignHeight="600" d:DesignWidth="800"
	Title="Achievement" Background="#FF2B579A" mc:Ignorable="d">
    <Page.Resources>
        <DataTemplate x:Key="ItemTemplate">
            <Grid Width="516.43" Height="111">
                <Grid.ColumnDefinitions>
                    <ColumnDefinition Width="0.147*" />
                    <ColumnDefinition Width="0.72*" />
                    <ColumnDefinition Width="0.132*" />
                    <ColumnDefinition Width="0.001*" />
                </Grid.ColumnDefinitions>
                <Grid.RowDefinitions>
                    <RowDefinition Height="0.793*" />
                    <RowDefinition Height="0.207*" />
                </Grid.RowDefinitions>

                <Image Source="{Binding Property1}" HorizontalAlignment="Stretch" Height="Auto" Width="Auto" Grid.Column="0" Grid.Row="0" Margin="1,2,4.915,16"/>
                <TextBlock Text="{Binding Property4}" Grid.Column="1" Grid.Row="0" HorizontalAlignment="Center" VerticalAlignment="Center" Margin="0,0,0.104,0" Width="369.029" Height="33.959" FontSize="24"/>
                <TextBlock Text="{Binding Property3}" Grid.Column="2" Grid.Row="0" HorizontalAlignment="Center" VerticalAlignment="Center" Width="35.94" FontSize="26.667"/>
                <TextBlock Text="{Binding Property2}" Grid.Row="1" HorizontalAlignment="Left" VerticalAlignment="Stretch" Width="516.94" Margin="0.084,-12.426,0,-4.427" Grid.ColumnSpan="4" FontSize="18.667"/>
                <Rectangle Grid.ColumnSpan="4" Fill="#FF2B579A" Height="7" Margin="-4,0,-34.57,0" Grid.Row="1" Stroke="#FF2B579A" VerticalAlignment="Bottom"/>
            </Grid>
        </DataTemplate>
        <Style x:Key="LegendStyle1" TargetType="{x:Type visualizationToolkit:Legend}">
            <Setter Property="Template">
                <Setter.Value>
                    <ControlTemplate TargetType="{x:Type visualizationToolkit:Legend}">
                        <Grid/>
                    </ControlTemplate>
                </Setter.Value>
            </Setter>
        </Style>
        <Style x:Key="LegendStyle2" TargetType="{x:Type visualizationToolkit:Legend}">
            <Setter Property="Template">
                <Setter.Value>
                    <ControlTemplate TargetType="{x:Type visualizationToolkit:Legend}">
                        <Grid/>
                    </ControlTemplate>
                </Setter.Value>
            </Setter>
        </Style>
        <SolidColorBrush x:Key="Brush1" Color="#FF2B579A"/>
    </Page.Resources>


    <Grid Background="#00000000" DataContext="{Binding Source={StaticResource AchievementList}}">
        <my:ComponentBar Height="70" Margin="0,0,0,0" x:Name="component_Bar1" VerticalAlignment="Top" />
        <ListBox Margin="205,201,34,57" ItemTemplate="{DynamicResource ItemTemplate}" ItemsSource="{Binding Collection}"/>
        <TextBlock Height="33" Margin="80,76,93,0" TextWrapping="Wrap" Text="Achievements" VerticalAlignment="Top" FontWeight="Bold" FontFamily="Sylfaen" FontSize="32" TextAlignment="Center" Foreground="#FFFFFBFB" TextDecorations="Underline"/>
        <chartingToolkit:Chart HorizontalAlignment="Left" 
			Margin="4,191,0,51" Name="columnChart" Title="Completion" Width="199" LegendStyle="{DynamicResource LegendStyle2}">
            <chartingToolkit:Chart.Axes>
                <chartingToolkit:LinearAxis Maximum="100" Interval="10" Orientation="Y" Margin="-44,3,0,0.72" HorizontalAlignment="Left" Width="55.35" ShowGridLines="True"/>

            </chartingToolkit:Chart.Axes>
            <chartingToolkit:ColumnSeries DependentValuePath="Value" 
			IndependentValuePath="Key" ItemsSource="{Binding}" Margin="1,0,-1,0" />
        </chartingToolkit:Chart>

    </Grid>
</Page>
